export {};

let fn = function (num: number, str: string): string {
  return "1";
};

fn(1, "s");

// fn(1) 必须全传

function fun(num: number, str: string = "1", ...args: [number]): void {}

fun(1, "1", 11111);

// 这种可以规定函数状态
let func: (num: number, str: string) => string = function (fn): string {
  return "666";
};

func(1, "cq");
